﻿using System;

class WorkDaysPeriod
{
    static void Main()
    {
        DateTime startDate = new DateTime(2013,01,17);
        DateTime endDate = DateTime.Now;
        TimeSpan span = endDate - startDate;
        DateTime[] holydays =
        {
            new DateTime(2013, 01, 18),
            new DateTime(2013, 01, 21),
            new DateTime(2013, 01, 22),
            new DateTime(2013, 01, 23),
            new DateTime(2013, 01, 24),
            new DateTime(2013, 01, 25),
            new DateTime(2013, 01, 26),
            new DateTime(2013, 01, 27),
            new DateTime(2013, 01, 28),
        };
        int counter = 0;

        for (int i = 0; i < span.Days; i++)
        {
            DateTime currentDay = startDate.AddDays(i);
            if (currentDay.DayOfWeek == DayOfWeek.Saturday || currentDay.DayOfWeek == DayOfWeek.Sunday)
            {
                continue;
            }
            bool isItAWorkingDay = true;
            for (int j = 0; j < holydays.Length; j++)
            {
                if (holydays[j].Day == currentDay.Day && holydays[j].Month == currentDay.Month)
                {
                    isItAWorkingDay = false;
                    break;
                }
            }
            if (isItAWorkingDay)
            {
                counter++;   
            }
        }

        Console.WriteLine("Total working days are {0} ",counter);
    }
}